<html>
<head><meta charset="utf-8"><title>terminology: const (generic) parameter · project-const-generics · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/index.html">project-const-generics</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html">terminology: const (generic) parameter</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="235346939"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/235346939" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#235346939">(Apr 20 2021 at 13:53)</a>:</h4>
<p>we're currently using both "const parameter" and "const generic parameter" in diagnostic and comments, I personally would like to be consistent here and always use the same terminology. I personal prefer just "const parameter". Any opinions?</p>



<a name="235356769"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/235356769" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#235356769">(Apr 20 2021 at 14:54)</a>:</h4>
<p>I prefer just <code>const parameter</code></p>



<a name="237394685"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237394685" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237394685">(May 04 2021 at 20:43)</a>:</h4>
<p>Looked into changing all occurrences of "const generic parameter" to just "const parameter".</p>
<p>I did see a few uses of "const generic argument" <span aria-label="thinking" class="emoji emoji-1f914" role="img" title="thinking">:thinking:</span> using "const argument" does not seem great. Do we just want to keep using "const generic argument" but use "const parameter"</p>



<a name="237398724"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237398724" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237398724">(May 04 2021 at 21:06)</a>:</h4>
<p><span class="user-group-mention" data-user-group-id="3805">@project-const-generics</span> <a href="https://github.com/rust-lang/rust/issues/84926">#84926</a> opinions?</p>



<a name="237399062"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399062" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Boxy [she/her] <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399062">(May 04 2021 at 21:08)</a>:</h4>
<blockquote>
<p>Const generic arguments</p>
</blockquote>



<a name="237399099"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399099" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Boxy [she/her] <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399099">(May 04 2021 at 21:08)</a>:</h4>
<p>do we still want to use this if we use const paramater elsewhere?</p>



<a name="237399143"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399143" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399143">(May 04 2021 at 21:08)</a>:</h4>
<p><span aria-label="shrug" class="emoji emoji-1f937" role="img" title="shrug">:shrug:</span></p>



<a name="237399232"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399232" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399232">(May 04 2021 at 21:08)</a>:</h4>
<p>idk, i do want to be consistent, but "const argument" seems slightly ambiguous to me</p>



<a name="237399292"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399292" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399292">(May 04 2021 at 21:09)</a>:</h4>
<p>though i guess the same can be said for "const parameter" <span aria-label="sweat smile" class="emoji emoji-1f605" role="img" title="sweat smile">:sweat_smile:</span></p>



<a name="237399323"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399323" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Boxy [she/her] <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399323">(May 04 2021 at 21:09)</a>:</h4>
<p>yes &gt;_&gt;</p>



<a name="237399358"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399358" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Boxy [she/her] <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399358">(May 04 2021 at 21:09)</a>:</h4>
<p>too bad we dont call it "type parameters"</p>



<a name="237399383"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399383" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Boxy [she/her] <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399383">(May 04 2021 at 21:09)</a>:</h4>
<p>"type generic arguments"</p>



<a name="237399485"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399485" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Boxy [she/her] <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399485">(May 04 2021 at 21:10)</a>:</h4>
<p><span class="user-mention silent" data-user-id="326176">Boxy</span> <a href="#narrow/stream/260443-project-const-generics/topic/terminology.3A.20const.20.28generic.29.20parameter/near/237399358">said</a>:</p>
<blockquote>
<p>too bad we dont call it "type parameters"</p>
</blockquote>
<p>hmm what <em>do</em> we use for type params?</p>



<a name="237399487"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399487" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399487">(May 04 2021 at 21:10)</a>:</h4>
<p>we do though, don't we?</p>



<a name="237399521"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399521" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399521">(May 04 2021 at 21:10)</a>:</h4>
<p><code>T</code> is a type parameter and <code>u32</code> is a type argument</p>



<a name="237399532"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399532" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> lcnr <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399532">(May 04 2021 at 21:10)</a>:</h4>
<p>i think</p>



<a name="237399580"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399580" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Boxy [she/her] <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399580">(May 04 2021 at 21:10)</a>:</h4>
<p>we should mirror that terminology then probably <span aria-label="thinking" class="emoji emoji-1f914" role="img" title="thinking">:thinking:</span></p>



<a name="237399727"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399727" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Boxy [she/her] <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399727">(May 04 2021 at 21:11)</a>:</h4>
<p><code>'a</code> is a lifetime parameter and <code>???</code> is a lifetime argument <span aria-label="sweat smile" class="emoji emoji-1f605" role="img" title="sweat smile">:sweat_smile:</span></p>



<a name="237399948"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237399948" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Boxy [she/her] <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237399948">(May 04 2021 at 21:12)</a>:</h4>
<p>for <code>struct Foo&lt;T&gt;;</code> the error message just calls it a "parameter"</p>



<a name="237405298"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237405298" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237405298">(May 04 2021 at 21:43)</a>:</h4>
<p><span class="user-mention silent" data-user-id="216206">lcnr</span> <a href="#narrow/stream/260443-project-const-generics/topic/terminology.3A.20const.20.28generic.29.20parameter/near/237394685">said</a>:</p>
<blockquote>
<p>I did see a few uses of "const generic argument" <span aria-label="thinking" class="emoji emoji-1f914" role="img" title="thinking">:thinking:</span> using "const argument" does not seem great. Do we just want to keep using "const generic argument" but use "const parameter"</p>
</blockquote>
<p>I think this was probably the reason it wasn't done earlier: "const argument" may suggest a normal argument that has a const value passed in, or something like that?</p>



<a name="237405331"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237405331" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237405331">(May 04 2021 at 21:43)</a>:</h4>
<p>It's hard to tell, because we all have a slightly different perspective than most Rust users.</p>



<a name="237405428"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237405428" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> varkor <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237405428">(May 04 2021 at 21:44)</a>:</h4>
<p>I'd have no objection to at least changing "const generic parameter" to "const parameter", though.</p>



<a name="237599154"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/237599154" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#237599154">(May 06 2021 at 03:17)</a>:</h4>
<p><span class="user-mention silent" data-user-id="121053">varkor</span> <a href="#narrow/stream/260443-project-const-generics/topic/terminology.3A.20const.20.28generic.29.20parameter/near/237405298">said</a>:</p>
<blockquote>
<p>I think this was probably the reason it wasn't done earlier: "const argument" may suggest a normal argument that has a const value passed in, or something like that?</p>
</blockquote>
<p>I might think that, or some kind of argument-position sugar for a const parameter</p>



<a name="238566792"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/260443-project-const-generics/topic/terminology%3A%20const%20%28generic%29%20parameter/near/238566792" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jubilee <a href="https://rust-lang.github.io/zulip_archive/stream/260443-project-const-generics/topic/terminology.3A.20const.20(generic).20parameter.html#238566792">(May 13 2021 at 01:03)</a>:</h4>
<p><span aria-label="wave" class="emoji emoji-1f44b" role="img" title="wave">:wave:</span> We talk about "const arguments" whenever we talk about supplying SIMD assembly instructions with the immediate values that they require, and also when discussing whether an argument, supplied as a constant, will be <em>optimized</em> into the desired assembly.</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>